package my.projects.jandan.ui;

import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JButton;
import javax.swing.JFrame;

import my.projects.jandan.thread.ThreadPoolMananger;

public class Window {
	public static void main(String[] args) {
		JFrame f = new JFrame("陌陌注册头像下载");
		f.setLayout(new FlowLayout());
		JButton btn1 = new JButton("开始");
		JButton btn2 = new JButton("停止");
		btn1.addActionListener(new ActionListener(){  
  
            public void actionPerformed(ActionEvent e) {  
            	new ThreadPoolMananger();
            }  
              
        });
		btn2.addActionListener(new ActionListener(){  
			  
            public void actionPerformed(ActionEvent e) {  
            	System.exit(0);
            }  
              
        });
		f.add(btn1);
		f.add(btn2);
		f.setSize(300, 150);
		f.setVisible(true);
		f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
	}

}
